home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 7 / BBS in a Box - Macintosh - Volume VII (BBS in a Box) (January 1993).iso / Files / Prog / T / TIFF Code.cpt / memory.c < prev    next >
Text File  |  1987-12-21  |  672b  |  48 lines

  1. /*
  2.  *    memory.c
  3.  *
  4.  *    Copyright (c) 1987 by Bear River Associates, Inc.
  5.  */
  6.  
  7. /* Primary Interface Files */
  8. #include "Types.h"
  9.  
  10. /* Other Interface files */
  11. #include "Memory.h"
  12.  
  13. /* Application-specific Include files */
  14. #include    "tifflib.h"
  15.  
  16. OSErr AllocPtr(ptrPtr, size)
  17. Ptr        *ptrPtr;
  18. Size    size;
  19. {
  20.     OSErr error;
  21.  
  22.     *ptrPtr = NewPtr(size);
  23.     error = MemError();
  24.     return(error);
  25. }
  26.  
  27. OSErr AllocMemory(ptrHandle, size)
  28. Handle    *ptrHandle;
  29. Size    size;
  30. {
  31.     OSErr error;
  32.     
  33.     *ptrHandle = NewHandle(size);
  34.     error = MemError();
  35.     return(error);
  36. }
  37.  
  38. OSErr AllocHandleSize(h, newSize)
  39. Handle    h;
  40. Size    newSize;
  41. {
  42.     OSErr error;
  43.     
  44.     SetHandleSize(h, newSize);
  45.     error = MemError();
  46.     return(error);
  47. }
  48.